﻿Public Class MDI

    Private Sub MDI_FormClosing(ByVal sender As Object, ByVal e As System.Windows.Forms.FormClosingEventArgs) Handles Me.FormClosing
        Conexion.Close()
    End Sub

    Private Sub MDI_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
        login.Close()
    End Sub

    Private Sub BarButtonItem15_ItemClick(sender As System.Object, e As DevExpress.XtraBars.ItemClickEventArgs) Handles BarButtonItem15.ItemClick
        My.Forms.frmFactura.MdiParent = Me
        My.Forms.frmFactura.Show()
    End Sub

    Private Sub BarButtonItem2_ItemClick(ByVal sender As System.Object, ByVal e As DevExpress.XtraBars.ItemClickEventArgs) Handles BarButtonItem2.ItemClick
        My.Forms.fUsuarios.MdiParent = Me
        My.Forms.fUsuarios.Show()
    End Sub

    Private Sub BarButtonItem16_ItemClick(sender As System.Object, e As DevExpress.XtraBars.ItemClickEventArgs) Handles BarButtonItem16.ItemClick
        My.Forms.frmTiposPago.MdiParent = Me
        My.Forms.frmTiposPago.Show()
    End Sub

    Private Sub BarButtonItem17_ItemClick(sender As System.Object, e As DevExpress.XtraBars.ItemClickEventArgs) Handles BarButtonItem17.ItemClick
        My.Forms.descuentostipos.MdiParent = Me
        My.Forms.descuentostipos.Show()
    End Sub

    Private Sub BarButtonItem18_ItemClick(sender As System.Object, e As DevExpress.XtraBars.ItemClickEventArgs) Handles BarButtonItem18.ItemClick
        My.Forms.FacturasHistorial.MdiParent = Me
        My.Forms.FacturasHistorial.Show()
    End Sub

    Private Sub BarButtonItem5_ItemClick(sender As System.Object, e As DevExpress.XtraBars.ItemClickEventArgs) Handles BarButtonItem5.ItemClick
        My.Forms.AgregarCategoriaDeducciones.MdiParent = Me
        My.Forms.AgregarCategoriaDeducciones.Show()
    End Sub

    Private Sub BarButtonItem23_ItemClick(sender As System.Object, e As DevExpress.XtraBars.ItemClickEventArgs) Handles BarButtonItem23.ItemClick
        My.Forms.Deducciones.MdiParent = Me
        My.Forms.Deducciones.Show()
    End Sub

    Private Sub BarButtonItem19_ItemClick(sender As System.Object, e As DevExpress.XtraBars.ItemClickEventArgs) Handles BarButtonItem19.ItemClick
        My.Forms.Planilla.MdiParent = Me
        My.Forms.Planilla.Show()
    End Sub

    Private Sub BarButtonItem6_ItemClick(ByVal sender As System.Object, ByVal e As DevExpress.XtraBars.ItemClickEventArgs) Handles BarButtonItem6.ItemClick
        My.Forms.Productos.MdiParent = Me
        My.Forms.Productos.Show()
    End Sub

    Private Sub BarButtonItem7_ItemClick(ByVal sender As System.Object, ByVal e As DevExpress.XtraBars.ItemClickEventArgs) Handles BarButtonItem7.ItemClick
        My.Forms.Proveedores.MdiParent = Me
        My.Forms.Proveedores.Show()
    End Sub

    Private Sub BarButtonItem13_ItemClick(ByVal sender As System.Object, ByVal e As DevExpress.XtraBars.ItemClickEventArgs) Handles BarButtonItem13.ItemClick
        My.Forms.CategoriaProductos.MdiParent = Me
        My.Forms.CategoriaProductos.Show()
    End Sub

    Private Sub BarButtonItem14_ItemClick(ByVal sender As System.Object, ByVal e As DevExpress.XtraBars.ItemClickEventArgs) Handles BarButtonItem14.ItemClick
        My.Forms.CategoriaUnidades.MdiParent = Me
        My.Forms.CategoriaUnidades.Show()
    End Sub

    Private Sub BarButtonItem20_ItemClick(ByVal sender As System.Object, ByVal e As DevExpress.XtraBars.ItemClickEventArgs) Handles BarButtonItem20.ItemClick
        My.Forms.UnidadesMedida.MdiParent = Me
        My.Forms.UnidadesMedida.Show()
    End Sub

    Private Sub BarButtonItem25_ItemClick(ByVal sender As System.Object, ByVal e As DevExpress.XtraBars.ItemClickEventArgs) Handles BarButtonItem25.ItemClick
        My.Forms.frmTipoNomina.MdiParent = Me
        My.Forms.frmTipoNomina.Show()
    End Sub

    Private Sub BarButtonItem8_ItemClick(ByVal sender As System.Object, ByVal e As DevExpress.XtraBars.ItemClickEventArgs) Handles BarButtonItem8.ItemClick
        My.Forms.frmEmpleado.MdiParent = Me
        My.Forms.frmEmpleado.Show()
    End Sub

    Private Sub BarButtonItem9_ItemClick(ByVal sender As System.Object, ByVal e As DevExpress.XtraBars.ItemClickEventArgs) Handles BarButtonItem9.ItemClick
        My.Forms.Clientes.MdiParent = Me
        My.Forms.Clientes.Show()
    End Sub

    Private Sub BarButtonItem10_ItemClick(ByVal sender As System.Object, ByVal e As DevExpress.XtraBars.ItemClickEventArgs) Handles BarButtonItem10.ItemClick
        My.Forms.Empresas.MdiParent = Me
        My.Forms.Empresas.Show()
    End Sub

    Private Sub BarButtonItem26_ItemClick(ByVal sender As System.Object, ByVal e As DevExpress.XtraBars.ItemClickEventArgs) Handles BarButtonItem26.ItemClick
        My.Forms.frmCargosvb.MdiParent = Me
        My.Forms.frmCargosvb.Show()
    End Sub
End Class